package com.hzy.oms.domain.bo;

import com.ruoyi.common.core.validate.AddGroup;
import com.ruoyi.common.core.validate.EditGroup;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.*;

import java.util.Date;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 订单管理业务对象 oms_order
 *
 * @author zengxin
 * @date 2023-10-18
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class OrderInfoBo extends BaseEntity {

    /**
     * 订单id
     */
    @NotNull(message = "订单id不能为空", groups = { EditGroup.class })
    private Long id;

    /**
     * 订单编号
     */
    @NotBlank(message = "订单编号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String orderSn;

    /**
     * 支付id
     */
    @NotNull(message = "支付id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long payId;

    /**
     * 会员id
     */
    @NotNull(message = "会员id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long memberId;

    /**
     * 用户帐号
     */
    @NotBlank(message = "用户帐号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String memberUsername;

    /**
     * 订单总金额
     */
    @NotNull(message = "订单总金额不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal totalAmount;

    /**
     * 采购价
     */
    @NotNull(message = "采购价不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal purchasePrice;

    /**
     * 应付金额
     */
    @NotNull(message = "应付金额不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal payAmount;

    /**
     * 运费金额
     */
    @NotNull(message = "运费金额不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal freightAmount;

    /**
     * 支付方式
     */
    @NotNull(message = "支付方式不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer payType;

    /**
     * 订单状态
     */
    @NotNull(message = "订单状态不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer status;

    /**
     * 退款状态
     */
    @NotNull(message = "退款状态不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer aftersaleStatus;

    /**
     * 物流公司
     */
    @NotBlank(message = "物流公司不能为空", groups = { AddGroup.class, EditGroup.class })
    private String deliveryCompany;

    /**
     * 物流单号
     */
    @NotBlank(message = "物流单号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String deliverySn;

    /**
     * 自动确认时间（天）
     */
    @NotNull(message = "自动确认时间（天）不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer autoConfirmDay;

    /**
     * 收货人姓名
     */
    @NotBlank(message = "收货人姓名不能为空", groups = { AddGroup.class, EditGroup.class })
    private String receiverName;

    /**
     * 收货人电话
     */
    @NotBlank(message = "收货人电话不能为空", groups = { AddGroup.class, EditGroup.class })
    private String receiverPhone;

    /**
     * 收货人邮编
     */
    @NotBlank(message = "收货人邮编不能为空", groups = { AddGroup.class, EditGroup.class })
    private String receiverPostCode;

    /**
     * 省份/直辖市
     */
    @NotBlank(message = "省份/直辖市不能为空", groups = { AddGroup.class, EditGroup.class })
    private String receiverProvince;

    /**
     * 城市
     */
    @NotBlank(message = "城市不能为空", groups = { AddGroup.class, EditGroup.class })
    private String receiverCity;

    /**
     * 区
     */
    @NotBlank(message = "区不能为空", groups = { AddGroup.class, EditGroup.class })
    private String receiverDistrict;

    /**
     * 省份/直辖市id
     */
    @NotNull(message = "省份/直辖市id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long receiverProvinceId;

    /**
     * 城市id
     */
    @NotNull(message = "城市id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long receiverCityId;

    /**
     * 区id
     */
    @NotNull(message = "区id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long receiverDistrictId;

    /**
     * 详细地址
     */
    @NotBlank(message = "详细地址不能为空", groups = { AddGroup.class, EditGroup.class })
    private String receiverDetailAddress;

    /**
     * 订单备注
     */
    @NotBlank(message = "订单备注不能为空", groups = { AddGroup.class, EditGroup.class })
    private String note;

    /**
     * 商家备注
     */
    @NotBlank(message = "商家备注不能为空", groups = { AddGroup.class, EditGroup.class })
    private String merchantNote;

    /**
     * 确认收货状态：0->未确认；1->已确认
     */
    @NotNull(message = "确认收货状态：0->未确认；1->已确认不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer confirmStatus;

    /**
     * 删除状态：0->未删除；1->已删除
     */
    @NotNull(message = "删除状态：0->未删除；1->已删除不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer deleteStatus;

    /**
     * 支付时间
     */
    @NotNull(message = "支付时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date paymentTime;

    /**
     * 发货时间
     */
    @NotNull(message = "发货时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date deliveryTime;

    /**
     * 确认收货时间
     */
    @NotNull(message = "确认收货时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date receiveTime;


}
